SQLExecutor
by Mai Nguyen, NeXT Developer Support

Overview
This example shows how to evaluate any arbitrary SQL statement for either the sybase or oracle adaptor.
If you use the Sybase adaptor, you will also be able to execute stored procedures that return computed rows or status rows. You must programmatically determine the type of rows returned in order to properly display the result sets. (see SybaseDelegate.[hm]).
If you use the Oracle adaptor, you can execute  the stored procedures, but you cannot process the results being returned.
For example, you can enter the following Oracle procedure in the evaluation panel:

BEGIN dbms_output.put_line('foobar'); END;

Program Organization

Major Classes in the Application
 
Evaluator	A generic object responsible for evaluating the SQL string  

SybaseDelegate	A delegate object responsible for handling the case of stored procedures that return computed rows
 
Topics Of Interest

How to open a connection to a database and close it via a model file
See the file Controller.m, method open:sender

How to evaluate a stored procedure or any other SQL string
This is done in the Evaluator class. See the method evaluate:  in the file Evaluator.m. See also the files SybaseDelegate.[hm]

Valid for NEXTSTEP Release 3.2 installed with the Enterprise Objects Framework Release 1.0,  1.1